#!/bin/bash
branch_v=$1
date_stamp=`date "+%Y-%m-%d %H:%M:%S"`
date1=`date "+%Y-%m-%d-%H-%M-%S"`
echo "$brance_v" 
DIANSHU_WEBSITE_HOME=$HOME/dianshu-website-frontend-old/

rm -rf /www/dianshu-website/v1/*
cp -r $DIANSHU_WEBSITE_HOME/dist/*   /www/dianshu-website/v1
sudo nginx -s reload
#cp -r /www/dianshu-website/  ~/dianshu-website-frontend/website-bak/dianshu-website$date1
send_weixin_v3   "【部署推送】\n【$date_stamp】\n【典枢】\n【frontend-website/前端/】\n【测试环境】【test-dianshu/49.234.77.139】\n【$branch_v】 分支部署完成, 由 $2 用户构建部署 "
